<template>
    <button v-on:click="clickOnClick">{{ title }}</button>
</template>
<script type="application/lua" lang="lua">
loader.export({
    data = function()
        return loader.obj({
            num = 1;
            title = "点我";
        })
    end;
    methods = loader.obj({
        clickOnClick = function(self)
            self.num = self.num + 1;
            self.title = '第' .. self.num .. '次点击x';
        end
    });
})
</script>
<style>
.btn {
    display: block;
}
</style>